/**
 * 车型管理
 */

import { createAPI } from '@/utils/request'

// 获取车辆类型信息列表
export const getCarListAPI = data => createAPI('/truckType/simple', 'get')

// 获取车辆类型分页数据
export const getCarListPageAPI = data => createAPI('/truckType/page', 'get', data)

// 删除车辆类型
export const deleteCarAPI = id => createAPI(`/truckType/${id}`, 'delete')

// 新增车辆类型
export const addCarAPI = data => createAPI(`/truckType`, 'post', data)

// 获取车辆类型详情
export const getCarDetailAPI = id => createAPI(`/truckType/${id}`, 'get')

// 更新车辆类型
export const updateCarDetailAPI = data => createAPI(`/truckType/${data.id}`, 'put', data)
